package cn.ljy.uem.model;

import cn.ljy.common.model.BaseModel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.Date;


/**
 * @description 行政班
 * @author 廖振豪
 * @date 2022-7-6 10:45
 */
@ApiModel(value="行政班")
@Data
@NoArgsConstructor
public class SchoolClass extends BaseModel {
    private Integer id;

    @ApiModelProperty(value = "行政班名称")
    @NotBlank(message = "名称不能为空")
    @Length(min = 2, max = 30, message = "名称长度必须在 {min} - {max} 之间")
    private String name;;//班级名称

    private Integer sort;//排序

    private Integer majorId;//所属专业

    private Integer gradeId;//年级

    private Long teacherId;//辅导员/班主任

    private Date createTime;//创建时间

    private Date updateTime;//修改时间


    //非数据库字段
    private SchoolMajor schoolMajor;//关联专业表

    private SchoolGrade schoolGrade;//关联成绩表

    private SchoolTeacher schoolTeacher;//关联教师表

    private Integer StudentNumber;//学生数量

}
